$(function() {

car()

function car() {
	var caropload = layer.load(0, {
		shade: [0.3, '#fff']
	});
	nomessage='暂无信息'
	$.ajax({
		type: "post",
		url: "{:url('adminapi/driver/searchCar')}",
		data: {
			page: {if $Think.get.page}{$Think.get.page}{else/}1{/if},
			pagenum: 10,
			uid: "{$uid}"
			{if $Think.get.number}
			,number:'{$Think.get.number}'
			{/if}
		},
		success: function(res) {
			layer.close(caropload);
			console.log(res);
			if(res.code == 1) {
				var mainarr=['time','company','number','role_id','car_type_name','carry','maintenance_record_price','mot_record_price','role_id','role_id','role_id','name','role_id','role_id','role_id','role_id']
				//表格内容
				tbody(res,mainarr,'caroperation',nomessage,false)
				//页码
				var urlmain=window.location.href;
				console.log();
				pagechang(res.data.count,10{if $Think.get.page},{$Think.get.page}{/if});
			} else {
				Err(res.msg)
			}
		}
	});
	
}
})